package com.atguigu.jeccache.entity.pojo;

import com.atguigu.jeccache.config.TimestampToLocalDateTimeDeserializer;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author Jungle
 * @create 2024-12-21 11:04
 */
@TableName("user")
@Data
public class User  implements Serializable {
    private Long id;
    private String name;
    private String password;
    @JsonDeserialize(using = TimestampToLocalDateTimeDeserializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;
    @JsonDeserialize(using = TimestampToLocalDateTimeDeserializer.class)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateTime;
}
